<div class="list_under blog_view">
    <ul>
		<?php 
if(!isset($deals))
{
	$deals = array();
}
if(!empty($deals))
{
	$currencySymbol = cr("DealConfig.currency_symbol");
	$dealCounter = 0;
	foreach ($deals as $deal)
	{ 
		$img = $html->image($deal['Deal']['image'], array('alt'=>$deal['Deal']['title'],'thumb'=>cr('Thumbs.listingMed'), 'height'=>'272', 'width'=>'470'));
		?>
        <li>
            <div class="col-xs-6 deal">
                <a href="<?php echo $deal['Deal']['viewUrl'];?>" title="<?php echo h($deal['Deal']['title']);?>">
                    <div class="image_decr">
                        <?php echo $img;?>
                        <div class="deal_decrip_bg">
                            <div class="deal_name">
                                <?php echo h($deal['Deal']['title']);?>                
                            </div>
                            <div class="deal_price" >
                                <span class="price">
									<?php $deal['Deal']['finalPrice'] = str_replace(",", "", $deal['Deal']['finalPrice']);
										echo $currencySymbol." ".number_format($deal['Deal']['finalPrice'],2,'.',''); ?>
								</span> 
                                <span class="line_through" style="text-decoration: line-through;"><?php echo $currencySymbol." ".number_format($deal['Deal']['regular_price'],2); ?></span>
                            </div>
                        </div><!--deal_decrip_bg--> 
                    </div>  <!--image_decr-->
                </a>
            </div> <!--deal-->    
        </li>
		<?php }
		}
		?>
	</ul>
</div>

<?php 
return;
if(!isset($deals))
{
	$deals = array();
}
if(!empty($deals))
{
	$currencySymbol = cr("DealConfig.currency_symbol");
	$dealCounter = 0;
	foreach ($deals as $deal)
	{
		$img = $html->image($deal['Deal']['image'], array('alt'=>$deal['Deal']['title'],'thumb'=>cr('Thumbs.listingMed'), 'height'=>'272', 'width'=>'470'));
		$dealCounter++;
		$dealLastClass = "";
		if($dealCounter % 3 == 0)
		{
			$dealLastClass = "last";
		}
		?>
		<div class="deal <?php echo $dealLastClass; ?>">
			<a href="<?php echo $deal['Deal']['viewUrl'];?>" title="<?php echo h($deal['Deal']['title'])?>">
				<div align="center">
					<div class="deal_name">
						<?php echo $deal['Deal']['title'];?>
					</div>
					<div class="image">
						<?php echo $img;?>
					</div> 
				</div>
				<?php //if($deal['Deal']['purchase_link_status']) { ?>
				<div>
					<span class="price fr"><?php 
					$deal['Deal']['finalPrice'] = str_replace(",", "", $deal['Deal']['finalPrice']);
					echo $currencySymbol." ".number_format($deal['Deal']['finalPrice'],2,'.',''); ?></span>
				</div>
				<div class="clear"></div>
				<div class="deal_des" align="center">
					<span style="text-decoration: line-through;"><?php echo $currencySymbol." ".number_format($deal['Deal']['regular_price'],2); ?></span>
				</div>
				<?php //} ?>
			</a>
		</div>
		<?php 
	}
}
?>